﻿using IBll;
using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;

namespace WebApi.Controllers
{
    [Route("api/[controller]")]
    [ApiController]
    public class UserController : ControllerBase,IUserBll
    {
        private IUserBll bll;

        public UserController(IUserBll bll)
        {
            this.bll = bll;
        }
        [HttpGet("Login")]
        public int Login(string name, string pwd)
        {
            return bll.Login(name, pwd);
        }
        [HttpGet("Show")]
        public dynamic Show(int pageindex = 1, int pagesize = 3)
        {
            return bll.Show(pageindex, pagesize);
        }
    }
}
